1. Field of the Invention
The embodiments of the invention relate to database management. Specifically, the embodiments of the invention relate to using middleware to conserve resources for maintaining a database.
2. Background
Many applications, operating systems, middleware (e.g. an application server runtime environment) and other programs utilize persistent data and data structures. This persistent data is stored in a persistent storage device such as a hard drive to be retrieved at a later time. This persistent data is often maintained in a database. Relational databases are organized into a set of tables and schemas. Each application, operating system, middleware or other program relies on and maintains its own set of tables.
At the time that an application, operating system or middleware is installed in a system, many of the tables that these programs utilize to store and retrieve data are initialized or created. These tables are generated and stored even if no data is ready to be stored in the table. Empty tables are created to service accesses, queries or similar operations that require the data of these tables. The empty tables include basic data structure data, definitions or metadata needed to maintain the table. These empty tables may occupy extensive physical space on a persistent storage device such as a hard drive. An empty table, i.e., a table with no data stored in the table, may occupy 32 kilobytes to 128 kilobytes or more in the persistent storage device. These numbers may greatly vary depending on the architecture of the relational database system.
A server often executes or supports multiple applications. Each application requiring its own set of tables to be maintained. Each application, individually, often requires a large number of empty tables at start up and during run-time. A large number of these tables remain empty for long periods of time. In aggregate, a server and database system maintain thousands, hundreds of thousands or more of empty tables. These empty tables occupy a large amount of space in the persistent storage devices of the server. The space occupied by these empty tables may occupy up to 10 gigabytes or more of hard drive or similar persistent storage device space.
In addition, the empty tables consume other system resources including processor time. Each table must intermittently have its data structure checked and its metadata updated. Even though these processes are infrequent, if a large number of tables are present in the system the impact on processor availability can be significant.